<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <div>
        编写函数has(arr , 60) 判断数组中是否存在60这个元素，返回布尔类型<br>
        var arr = [1, 2, 3, 60]<br>
        var arr2 = [1, 2, 3]<br>
        function has() {<br>
        // code in here ...<br>
        }<br>
        console.log(has(arr, 60)) // true<br>
        console.log(has(arr2, 60)) // false<br>
    </div>
    <script>
        function Has( arr , b ){
            if ( arr.indexOf(b) != -1 ) {
                return true ;
            } else {
                return false ;
            }
        }
        var arr = [1,2,3,60]
        var arr2 = [1,2,3]
        console.log(Has(arr,60));
        console.log(Has(arr2,60));
    </script>
</body>
</html>